package com.yue.ssa.bean;

import com.baomidou.mybatisplus.annotation.TableField;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;

import java.io.Serializable;
import java.util.Date;
import java.util.List;

@ApiModel("角色")
public class Role implements Serializable {

    @ApiModelProperty("主键")
    private String id;
    @ApiModelProperty("英文名称")
    private String name;
    @ApiModelProperty("中文名称")
    private String nameZh;
    @ApiModelProperty("创建时间")
    private Date createTime;
    @ApiModelProperty("资源列表")
    @TableField(exist = false)
    private List<Menu> menuList;

    public String getId() {
        return id;
    }

    public void setId(String id) {
        this.id = id;
    }

    public String getName() {
        return name;
    }

    public void setName(String name) {
        this.name = name == null ? null : name.trim();
    }

    public String getNameZh() {
        return nameZh;
    }

    public void setNameZh(String nameZh) {
        this.nameZh = nameZh;
    }

    public Date getCreateTime() {
        return createTime;
    }

    public void setCreateTime(Date createTime) {
        this.createTime = createTime;
    }

    public List<Menu> getMenuList() {
        return menuList;
    }

    public void setMenuList(List<Menu> menuList) {
        this.menuList = menuList;
    }

    //    @Override
//    public int hashCode() {
//        return id.hashCode();
//    }
//
//    @Override
//    public boolean equals(Object obj) {
//        if (obj instanceof Role) {
//            Role role = (Role) obj;
//            return this.id.equals(role.id);
//        }
//        return false;
//    }
}